/**
 * 
 * @authors Your Name (you@example.org)
 * @date    2015-05-18 19:39:49
 * @version $Id$
 */

define([], function () {
  var mode = 'prod';
  modes = {
        prod: {
          adminLogin: '/flight/adminV2/dashboard/admin/login',
          missionList: '/flight/adminV2/dashboard/mission/list',
          activeCode: '/flight/adminV2/dashboard/activeCode/list',
          missionOperate: '/flight/adminV2/dashboard/mission/operate',
          questOperate: '/flight/adminV2/dashboard/quest/operate',
          activeCodeUpdate:'/flight/adminV2/dashboard/activeCode/update',
          dau: '/flight/adminV2/dashboard/dau',
          dnu: '/flight/adminV2/dashboard/dnu',
          storeList: '/flight/adminV2/dashboard/store/list',
          storeUpdate: '/flight/adminV2/dashboard/store/update',
          childrenList: '/flight/adminV2/dashboard/children/list',
          childrenRejust: '/flight/adminV2/dashboard/children/rejust',
          childrenAccountStateChange: '/flight/adminV2/dashboard/children/account/state/change',
          childrenClearDate: '/flight/adminV2/dashboard/children/clear/data',
          childrenViewMission: '/flight/adminV2/dashboard/children/find/mission/data',
          childrenMissionQuestClear: '/flight/adminV2/dashboard/children/clear/quest/data',
          childrenMissionClear: '/flight/adminV2/dashboard/children/clear/mission/data',
          childrendelete: '/flight/adminV2/dashboard/children/delete',
          childrenAddItem: '/flight/adminV2/dashboard/children/item/list',
          quests: '/flight/adminV2/dashboard/mission/quests',
          questTypes: '/flight/adminV2/dashboard/mission/quest/type/list',
          singleQuest: '/flight/adminV2/dashboard/mission/{missionId}/quest/{questId}',
          items: '/flight/adminV2/dashboard/item/list',
          itemOperate: '/flight/adminV2/dashboard/item/operate',
          getItemById: '/flight/adminV2/dashboard/item/{itemId}',
          findInventory: '/flight/adminV2/dashboard/children/find/inventory/data',
          findGameSession: '/flight/adminV2/dashboard/children/find/game/session/data',
          childrenItem: '/flight/adminV2/dashboard/children/item/add',
          uploadItemIcon: '/flight/adminV2/dashboard/item/icon/upload',
          parentList: '/flight/adminV2/dashboard/parents/list',
          parentDelete: '/flight/adminV2/dashboard/parents/delete',
          parentChangeEnable: '/flight/adminV2/dashboard/parents/user/enable',
          parentChangeDisable: '/flight/adminV2/dashboard/parents/user/disable',
          parentChangeDebugEnable: '/flight/adminV2/dashboard/parents/debug/enable',
          parentChangeDebugDisable: '/flight/adminV2/dashboard/parents/debug/disable',
          parentChildAdd: '/flight/adminV2/dashboard/child/add/v2',
          adminList: '/flight/adminV2/dashboard/adminuser/list',
          adminAdd: '/flight/adminV2/dashboard/adminuser/add',
          adminDelete: '/flight/adminV2/dashboard/adminuser/delete',
          
         
        },

        dev: {
          childProgress: 'js/app/json/childProgress.json',
          childSessions: 'js/app/json/childSessions.json',
          detailSession: 'js/app/json/detailSession.json',
          playedDays: 'js/app/json/childPlayedDays.json',
          tipsDirectory: 'js/app/json/tipsDirectory.json',
          todayTips: 'js/app/json/todayTips.json',
          register: 'js/app/json/register.json',
          changeChild: 'js/app/json/changeChild.json'
        },

        local: {
          register: '/flight/dashboard/v3/register',
          login: '/flight/dashboard/v3/user/login',
          children: '/flight/dashboard/v3/${accessToken}/children',
          childProgress: '/flight/dashboard/v3/${accessToken}/progress/detail',
          changeChild: '/flight/dashboard/v3/${accessToken}/child/change',
          childSessions: '/flight/dashboard/v3/${accessToken}/sessions/detail',
          detailSession: '/flight/dashboard/v3/${accessToken}/session/${gameSessionId}/detail',
          playedDays: '/flight/dashboard/v3/${accessToken}/session/record',
          tipsDirectory: 'http://www.flightcms.com/flight/flight_web_service',
          todayTips: 'http://www.flightcms.com/flight/flight_web_service',
          uploadAvatar: '/flight/dashboard/v3/upload',
          settings: '/flight/dashboard/v3/${accessToken}/user/update',
          parent: '/flight/dashboard/v3/${accessToken}/user/info',
          updateAccount: '/flight/dashboard/v3/${accessToken}/user/update',
          forgotPasswd: '/flight/dashboard/v3/password/reset',
          help: 'http://dev.flight.gamecloudstudios.com/cms/flight/flight_help'
        }
      };

  var _get = function(key) {
    return modes[mode][key];
  };

  return {
    adminDeleteURL:function(){
      return _get('adminDelete');
    },
    adminAddURL:function(){
      return _get('adminAdd');
    },
    adminListURL:function(){
      return _get('adminList');
    },
    parentChildAddURL:function(){
      return _get('parentChildAdd');
    },
    parentChangeDebugEnableURL:function(){
      return _get('parentChangeDebugEnable');
    },
    parentChangeDebugDisableURL:function(){
      return _get('parentChangeDebugDisable');
    },
    parentChangeEnableURL:function(){
      return _get('parentChangeEnable');
    },
    parentChangeDisableURL:function(){
      return _get('parentChangeDisable');
    },
    parentDeleteURL:function(){
      return _get('parentDelete');
    },
    parentListURL:function(){
      return _get('parentList');
    },
    childrenItemURL:function(){
      return _get('childrenItem');
    },
    findGameSessionURL: function(){
      return _get('findGameSession');
    },
    findInventoryURL: function(){
      return _get('findInventory');
     },
    childrenAddItemURL: function(){
      return _get('childrenAddItem');
     },
    childrendeleteURL: function(){
      return _get('childrendelete');
     },
    childrenMissionQuestClearURL: function(){
      return _get('childrenMissionQuestClear');
     },
    childrenMissionClearURL: function(){
      return _get('childrenMissionClear');
     },
    childrenViewMissionURL: function(){
      return _get('childrenViewMission');
     },
    childrenClearDateURL: function(){
      return _get('childrenClearDate');
     },
    childrenAccountStateChangeURL: function(){
      return _get('childrenAccountStateChange');
     },
    childrenRejustURL: function(){
      return _get('childrenRejust');
     },
    childrenListURL: function(){
      return _get('childrenList');
    },
    loginURL: function() {
      return _get('adminLogin');
    },
    storeListURL: function(){
      return _get('storeList');
    },
    storeUpdateURL: function(){
      return _get('storeUpdate');
    },
    activeCodeUpdateURL: function(){
      return _get('activeCodeUpdate');
    },
	  listActiveCodesURL: function(){
	   return _get('activeCode');
	   },
    parentListURL: function() {
      return _get('parentList');
    },
    listMissionURL: function() {
      return _get('missionList');
    },
    missionOperateURL: function() {
      return _get('missionOperate');
    },
    questOperateURL: function() {
      return _get('questOperate');
    },
    questTypesURL: function() {
      return _get('questTypes');
    },
    findQuestURL: function() {
      return _get('singleQuest');
    },
    getDAUURL: function() {
      return _get('dau');
    },
    getDNUURL: function() {
      return _get('dnu');
    },
    listQuestsURL: function() {
      return _get('quests');
    },
    listItemsURL: function() {
      return _get('items');
    },
    itemOperateURL: function() {
      return _get('itemOperate');
    },
    getItemURL: function() {
      return _get('getItemById');
    },
    uploadItemIcon: function () {
      return _get('uploadItemIcon');
    }
  };
})